Blog search

Friday Facts #217 - Just another Friday Facts

Posted by Twinsen & Rseding91 on 2017-11-17

Hello, most of the team is out of the office today attending the Game Developers Session here in Prague, if you're around you can look out for some people wearing Factorio t-shirts. As we were thinking about what to write in this Friday Facts, kovarex suggested "In the next Friday Facts we should write about how hard it is to write Friday Facts". Sometimes it is really difficult to find something interesting to write about. Thankfully we found some short things that that we thought you would like.

Friday Facts #223 - Reflections on 2017

Posted by kovarex on 2017-12-29

Hello, this is the last Friday of 2017, and as such, the last Friday facts of this year.

Friday Facts #406 - Space Age Music

Posted by Albert on 2024-04-12

It was November of 2021 when we started conversations with Petr Wajsar, a very talented Czech music composer, to create the soundtrack for the Factorio expansion. Since then we have been working together on the soundtrack of Factorio Space Age. Conceptualising and finding solutions to our not small amount of problems, and filling the expansion with quality music, specially designed for the best possible Factorio experience. Petr is a very special musician, because besides being a proven master of electronic music, his education and experience in the conservatory makes him capable of composing music using the full range of a classic orchestra. His modern style of going to more experimental solutions, makes him very flexible at creating the score of the Factorio Space Age expansion.

Friday Facts #415 - Fix, Improve, Optimize

Posted by Rseding on 2024-06-14

Hello, While a lot of time of 2.0 development has been spent on new features and quality of life, we still take care of the smaller details and technical improvements.

Friday Facts #409 - Diminishing beacons

Posted by V453000, Earendel on 2024-05-03

Hello, Today we're going to take a look at a feature some of us have dreamt of changing for years now - the beacon transmission. The main purpose of beacons is to allow massively increasing your production in the late game while being more than just a module or a faster machine. To make use of beacons you need to adjust your building layout for them. Beacons succeed in this role, but...

Friday Facts #244 - Localised plurals & Modernisation progress

Posted by Klonan, kovarex, Posila on 2018-05-25

New Python developer (Klonan) Mobile users may see that the website is significantly easier to read today, that is all thanks to our new Python developer Sanqui. Apart from making our website more mobile friendly, we have a lot of tasks on the backlog that he will start working on soon. His first major task is to speed up and optimize the matching server, with which he is already making some progress. A bigger rewrite for the long term is underway, but in the last week he has reduced a lot of the slowness and timeouts people were seeing during peak times. He will be taking over our database management and web administration from HanziQ, as well as spending time cleaning up our codebase, maintaining our web services, and developing features for the mod portal.

Friday Facts #89 - Timetables

Posted by kovarex on 2015-06-05

Hello, the current week was the time of merges. Different branches with functionalities were merged into the master branch: traingulations(finally), combinators, robot beams, personal roboport and others. Every other day the game/tests didn't work, because some merge broke something. But now it is starting to be stabilised again.

Friday Facts #172 - Blending and Rendering

Posted by Posila & V453000 on 2017-01-06

Alpha blending and pre-multiplied alpha From time to time there is some confusion inside the team about how sprites are blended with the background when rendering, and what kind of effects we are able to achieve by tinting the sprites. So I (Posila) have decided to write up a few paragraphs about how alpha blending works (not only in Factorio), and what it means when someone talks about pre-multiplied alpha. When the GPU is figuring out what color it should draw on a particular pixel position, it runs a blending operation on just the computed pixel color and original color in the render target. There are several common blending operation modes (additive, multiplicative, overwrite, etc.), but the most common one used in Factorio is alpha blending. It calculates the resulting color using following equation (usually the new color is called 'source' and the background color that is being overwritten is called 'destination'): You can easily see that a source with alpha 0 will be fully transparent and the one with alpha 1 will be fully opaque. In games it is common to use a pre-multiplied alpha, which means the color channels of textures are stored in memory being already pre-multiplied by the alpha channel. Alpha blending with pre-multiplied alpha uses a simplified equation: Besides a slight performance gain from the GPU not having to do bunch of multiplication all the time, this equation allow us to do some extra effects we couldn't do without pre-multiplied alpha. Factorio renders sprites as colored polygons with texture. We usually refer to the color of a polygon as the 'tint', and every pixel of a sprite is multiplied with its tint. This is useful mainly for color masks, for example the diesel locomotive has a grayscale color mask which is tinted by the color it has set. Tints should have a pre-multiplied alpha too, but they don't have to, so we can use it to lie about the colors and alpha to the GPU. For example if we use tint {r=1,g=1,b=1,a=0} we can simplify previous equation even further and we get additive blending: This is great because that means we can switch between alpha and additive blending without having to change the blending state in graphics API, which would break sprite batching and result in an increase in the CPU cost of rendering. For some effects we use a tint with alpha between 0 and 1 heavily. This makes the result appear to be a combination of additive and alpha blending. For example, fire would eventually blend into a single solid color with pure additive blending, or would not look like it is emitting light with pure alpha blending. By using tint (1, 1, 1, 0.35) on the flame sprites, the brightness of overlapping flames adds up partially, but the flames don't completely lose their details. The same trick is used for smoke. Textures with pre-multiplied alpha also produce better results in texture filtering , which is probably the main reason why they are so widely used in the videogame industry.

Friday Facts #82 - Optimisations

Posted by kovarex on 2015-04-17

Hello factorio builders, I hope you enjoy lists and numbers, because you are going to be fed by these today :).

Friday Facts #218 - Import bpy, Export player

Posted by V453000 & Twinsen on 2017-11-24

Hello dear biters and related species from unexplored planet full of life and natural resources. Recently I have been working on several high resolution graphics for your best friends - the tank and the player character. In this article I would like to show their updated visuals to you, as well as a sneak peek at how they are produced. The following text may contain traces of automation.